/* 全局样式 */
@use './tailwind.css';
@use './nprogress.css';
@use './element-plus.scss';
@use './iconFont.scss';
@use './transition.scss';
* {
  box-sizing: border-box;
}

html,
body {
  user-select: none;
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB',
    'Microsoft YaHei', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

#app {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

/* 滚动条样式 */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb {
  background: #c1c1c1;
  border-radius: 4px;
  transition: background 0.3s;
}

::-webkit-scrollbar-thumb:hover {
  background: #a8a8a8;
}

/* 暗黑模式滚动条 */
.dark ::-webkit-scrollbar-track {
  background: #2c2c2c;
}

.dark ::-webkit-scrollbar-thumb {
  background: #4c4c4c;
}

.dark ::-webkit-scrollbar-thumb:hover {
  background: #6c6c6c;
}

/* Element Plus 暗黑模式适配 */
html.dark {
  color-scheme: dark;
}

/* 禁用文本选择（可选） */
.no-select {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}

/* 页面过渡动画 */
.fade-enter-active,
.fade-leave-active {
  transition: opacity 0.3s ease;
}

.fade-enter-from,
.fade-leave-to {
  opacity: 0;
}

.slide-enter-active,
.slide-leave-active {
  transition: all 0.3s ease;
}

.slide-enter-from {
  transform: translateX(-30px);
  opacity: 0;
}

.slide-leave-to {
  transform: translateX(30px);
  opacity: 0;
}
